import type { App } from 'vue';
import vHoverGradient from './v-hover-gradient';
import vHoverBg from './v-hover-bg';
import vSlideUnderline from './v-slide-underline';
import vImgZoom from './v-img-zoom';
import vLikePulse from './v-like-pulse';
import vSvgHover from './v-svg-hover';

export const directives = {
  'hover-gradient': vHoverGradient,
  'hover-bg': vHoverBg,
  'slide-underline': vSlideUnderline,
  'img-zoom': vImgZoom,
  'like-pulse': vLikePulse,
  'svg-hover': vSvgHover,
};
// 全局注册函数
export const setupDirectives = (app: App) => {
  Object.entries(directives).forEach(([name, directive]) => {
    app.directive(name, directive);
  });
};
